package com.example.kotlin.glide;

import com.bumptech.glide.annotation.GlideExtension;
import com.bumptech.glide.annotation.GlideOption;
import com.bumptech.glide.request.BaseRequestOptions;
import com.example.kotlin.R;

/**
 * @ClassName: MyGlideExtension
 * @Description: java类作用描述
 * @Author: chenmengjia
 * @Date: 2022/2/24 11:19
 */
@GlideExtension
public final class MyGlideExtension {
   private MyGlideExtension() {
    }
@GlideOption
    public static BaseRequestOptions<?> applyAvatar(BaseRequestOptions<?> options, int size) {


        return options.placeholder(R.mipmap.ic_launcher).error(R.mipmap.ic_launcher).override(size).centerCrop();

    }

}
